package com.kizitonwose.calendarview;

import com.kizitonwose.calendarview.fraction.BaseFraction;

/**
 * @author LiuQingHua
 * @version 1.0
 * @date 2021/2/18/ 15:03
 */
public class ExampleItem {

    private int titleRes;
    private int subtitleRes;
    private Function<BaseFraction> createView;

    public ExampleItem(int titleRes, int subtitleRes, Function<BaseFraction> createView) {
        this.titleRes = titleRes;
        this.subtitleRes = subtitleRes;
        this.createView = createView;
    }

    public int getTitleRes() {
        return titleRes;
    }

    public void setTitleRes(int titleRes) {
        this.titleRes = titleRes;
    }

    public int getSubtitleRes() {
        return subtitleRes;
    }

    public void setSubtitleRes(int subtitleRes) {
        this.subtitleRes = subtitleRes;
    }

    public BaseFraction getCreateView() {
        return createView.invoke();
    }

}
